package com.flyxteam.learner.springboot;

import org.springframework.context.annotation.*;

import com.flyxteam.learner.springboot.endpoint.SomeEndpoint;

import org.springframework.boot.actuate.endpoint.Endpoint;
import org.springframework.boot.autoconfigure.SpringBootApplication;

// ## SpringBoot核心注解，开启自动配置 (默认开启自动配置、扫描当前所在包以及子包)
@SpringBootApplication(
    // ## 排除的自动配置类，见启动日志的Exclusions
    excludeName = { 
        "org.springframework.boot.autoconfigure.jms.activemq.ActiveMQAutoConfiguration",
        "org.springframework.boot.autoconfigure.social.FacebookAutoConfiguration",
    }
)
// ## 只可引入xml配置文件
@ImportResource(locations = { "classpath*:/context/*.xml" })
public class ApplicationConfig {

    // ## 注册一个自定义的Endpoint
    @Bean
    Endpoint<Object> some() {
        return new SomeEndpoint();
    }
    
}
